xml spy
New...
[Previous] [Main] [Next]

The "New..." command is used to create a new document with XML Spy. You are presented a list of predefined document types that you can create:

editing_new.gif


Since XML is such a versatile and universal concept, there are many different kinds of XML documents that you can create and edit with XML Spy. If the document you want to create is not listed, you can simply select ".xml" and later change the extension when you save the file. You can also add new file types to this list using the File Type Settings dialog.

XML Spy contains built-in templates for most XML-based document types and will automatically provide you with a meaningful starting point instead of a totally empty file (e.g. a ".xhtml" file automatically includes the correct DOCTYPE reference to the XHTML DTD as well as an empty <html> element to start with).

If you did select a plain ".xml" file (typically a new XML instance document) in the above dialog, you can still provide XML Spy with a DTD or Schema that you want your new file to be based upon:

editing_new_dtdschema.gif


If you instead wish to start with a plain empty XML file, simply click the "Cancel" button in this dialog.

If you clicked on OK and the content model of the Schema or DTD contains more than one potential candidate for being a root element, XML Spy asks you to select a root element from the list of possible candidates:

select_root.gif


The new document is then automatically created with this element as its document root.

© 2000 Altova